package com.ylkj.wx.dao.impl;

import java.sql.SQLException;

import org.hibernate.HibernateException;
import org.hibernate.Session;
import org.springframework.orm.hibernate3.HibernateCallback;
import org.springframework.stereotype.Repository;

import com.ylkj.common.base.BaseDaoHibernate;
import com.ylkj.wx.dao.EvaluateDAO;
import com.ylkj.wx.entitis.EvaluateInfoEntity;

/**
 * 评价dao
 * @author baoy
 *
 */
@Repository
public class EvaluateDAOImpl extends BaseDaoHibernate implements EvaluateDAO{

	@Override
	public void saveEvaluateInfo(final EvaluateInfoEntity entity) {
		 getHibernateTemplate().execute(new HibernateCallback<Boolean>() {@Override
		        public Boolean doInHibernate(Session session)
		        		throws HibernateException, SQLException {
		        	session.saveOrUpdate(entity);
		        	return true;
		        }
				});
		
	}

}
